import request from './request'

export function search(data) {
    return request({
        url: 'share/platform-service/dictionary/search',
        method: 'post',
        data
    })
}

export function getTree() {
    return request({
        url: 'share/platform-service/dictionary/tree'
    })
}

export function saveOrUpdate(data,action) {
    return request({
        url: 'share/platform-service/dictionary/'+action,
        method: 'post',
        data
    })
}
export function getAllCodeTypeTree() {
    return request({
        url: 'share/platform-service/dictionary/allCodeType'
    })
}
export function deleteData(data) {
    return request({
        url: 'share/platform-service/dictionary',
        method: 'delete',
        data
    })
}
export function getById(params) {
    return request({
        url: 'share/platform-service/dictionary/Id/'+params,
    })
}